.hover-container {
  width: 300px;
  height: 100px;
  border: 2px solid #333;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.moving-text {
  margin: 0;
  position: absolute;
  left: -100%;  /* 初始位置在盒子外面 */
  transition: left 0.5s ease;  /* 平滑过渡效果 */
}

.hover-container:hover .moving-text {
  left: 10%;  /* 鼠标悬停时，文字移动到盒子内 */
}